//
//  AIRatingView.h
//  AIRatingView
//
//  Created by Ailix on 15/4/2.
//  Copyright (c) 2015年 Ailix. All rights reserved.
//

#import <UIKit/UIKit.h>


@class AIRatingView;

@protocol AIRatingViewDelegate <NSObject>


- (void)ratingView:(AIRatingView *)ratingView didUpdateRating:(CGFloat)currentRating;

@end

@interface AIRatingView : UIView


/** 空星 */
@property (nonatomic) UIImage *notSelectedImage;

/** 半星 */
@property (nonatomic) UIImage *halfSelectedImage;

/** 满星 */
@property (nonatomic) UIImage *fullSelectedImage;

/** 当前星数 */
@property (nonatomic) CGFloat currentRating;

/** 最大星数 */
@property (nonatomic) CGFloat maxRating;

/** 左右边距 */
@property (nonatomic) CGFloat sideMargin;

/** 星间距 */
@property (nonatomic) CGFloat middleMargin;

/** 是否可以评分 */
@property (nonatomic) BOOL editable;

@property (nonatomic,weak) id <AIRatingViewDelegate> delegate;

@end
